﻿@*  Ui层项目 - 编辑页文件  *@
@using Util.Generators.Helpers
@model Util.Generators.Contexts.EntityContext
@{
    var service = new GenerateService( Model );
}
@("@page")
@("@model") @(service.EntityName)Dto

@@*表单*@@
<util-card bordered="false">
    <util-form label-span="6" control-span="18" gutter="24">
        @foreach (var property in Model.Properties)
        {
            if (property.IsKey)
                continue;
            if (property.IsDeleted)
                continue;
            if (property.IsExtraProperties)
                continue;
            if (property.IsVersion)
                continue;
            if (property.IsPinYin)
                continue;
            if (property.IsAudited)
                continue;
            if ( property.IsGuid )
                continue;
            if (property.IsDateTime)
            {
        <util-date-picker for="@property.Name" />
                continue;
            }
            if (property.IsBool)
            {
        <util-switch for="@property.Name" />
                continue;
            }
        <util-input for="@property.Name" />
        }
        <util-drawer-footer justify="FlexEnd">
            <util-button on-click="close()" text-cancel="true"></util-button>
            <util-button id="btnSubmit" is-submit="true" validate-form="true" type="Primary" on-click="submit(btnSubmit)" text-ok="true"></util-button>
        </util-drawer-footer>
    </util-form>
</util-card>
